Repository navigation
improve(web): workspace settings explain deletion and an empty ownership transfer - #327
Conversation
|
🦞👀 Pull request received. I will update this pull request when review starts. ClawSweeper review completeClawSweeper finished reviewing this revision. The review result is being finalized. |
|
Codex review: needs maintainer review before merge. What this changesThe workspace overview explains deletion confirmation, labels its input, and explains an empty ownership-transfer selector. Example: Acme Support has only its owner.
Review scores
ProductKind: Bug fix · Worth it: Yes · Fix scope: Complete Merge readiness✅ Ready for maintainer review This PR provides a useful accessibility and usability fix absent from current main; no actionable correctness or security defect was found. Priority: P3 Before mergeNone. FindingsNone. Agent review detailsHow this fits togetherThe workspace overview receives workspace identity and the member directory, renders existing administration controls, and submits transfer or deletion requests through unchanged APIs. flowchart TD
A[Workspace owner] --> B[Overview settings]
C[Workspace identity] --> B
D[Member directory API] --> E[Existing eligibility filter]
E --> B
B --> F[Confirmation and empty state hints]
B --> G[Workspace administration API]
Technical reviewBest possible solution: Keep the explanations and accessible label in the existing overview page while preserving its administration rules. Do we have a high-confidence way to reproduce the issue? Current-main source exposes the unnamed deletion input and unexplained empty selector, corroborated by the contributor's before screenshot; no target code was run during this review. Is this the best way to solve the issue? The patch uses the existing successful-load marker and eligibility list, providing a small complete fix without introducing a second owner or changing APIs. AGENTS.md: found and applied where relevant. Codex review notes: model internal, reasoning medium; reviewed against 03e85d6c704a. Provenance checked
TestingProof path: shipped entry point. SecurityNone. EvidenceWhat I checked:
Likely related people:
Preflight sourceSource unknown. Source comparison at the observed PR snapshot only. Completion is self-reported; body, policy, tests, execution, and report bytes are not verified. LabelsLabel changes:
Label justifications:
Rating scale6/6 🦀 challenger crab · 5/6 🦞 diamond lobster · 4/6 🐚 platinum hermit · 3/6 🦐 gold shrimp · 2/6 🦪 silver shellfish · 1/6 🧂 unranked krab. Overall follows the weaker of proof and patch quality; ✨ marks media proof (a screenshot, video, or linked artifact) that directly shows the changed behavior. WorkflowClawSweeper edits this one comment on every review. Comment HistoryReview history (1 earlier review cycle)
Reviewed November 9, 2026, 3:50 AM ET / 08:50 UTC (Revision 2). |
|
@clawsweeper re-review |
|
🦞👀 Re-review progress:
|
What Problem This Solves
Fixes: a workspace owner opening Settings → Overview cannot tell how to delete the workspace or why ownership cannot be transferred.
User Impact
User impact: owners see "Type the workspace name to confirm." next to the delete field, and screen readers announce the field's purpose. A workspace with no eligible member shows "No eligible members" and "Add a human member who is not a guest first." instead of a blank menu.
No behavior changes: delete still needs the exact name, transfer still goes to the same members, and the API is untouched. While the member list is loading or has failed, the empty message stays hidden, so a failed load does not claim there are no members.
Why This Change Was Made
The confirmation rule lived only in
canDelete, and the page had no state for "the member list loaded and nobody qualifies". This adds the hint, anaria-label, and a derivednoTransferMembersstate.docs/features/workspaces.mdgets one line, andapps/api/internal/webassets/distis rebuilt because CI requires it to be current.Evidence
Real server (
clickclack serve --dev-bootstrap=true, Linux) with a newly created workspace that has only its owner, in headless Chrome at 1280×800. Same steps on both builds.New Playwright spec
tests/e2e/workspace-danger-zone.spec.ts, run against those same builds:The two failures on base are the delete hint and the empty transfer state. The delete field's accessible name is "Name to confirm deletion", so the existing
getByLabel("Workspace name")selectors intests/e2e/routing.spec.tsstill match only the profile field:playwright test tests/e2e/workspace-danger-zone.spec.ts tests/e2e/routing.spec.ts→ 18 passed on the branch. The third test passes on both: it guards the failed-load and has-member states, where the empty message must stay hidden. It serves the member list through a mocked route, because the HTTP API cannot add a human member.Not tested: a real transfer or deletion (the spec only checks that the delete button enables), the desktop app, and a real screen reader. The accessible name is checked through Playwright's role query.